HTMLify
style.css
Views: 19 | Author: cody
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 | body { height: 100vh; overflow: hidden; background: linear-gradient(18deg, #e37682, #a58fe9); display: flex; flex-wrap: wrap; justify-content: space-evenly; align-items: center; } .hexagon-wrapper { margin: auto; display: flex; text-align: initial; width: 200px; height: 200px; cursor: pointer; } .hexagon { position: relative; width: 46%; height: 80%; margin: auto; color: white; background: linear-gradient(-180deg, white, #fda3b2); display: flex; align-content: center; justify-content: center; transition: 0.5s; } .hexagon i { z-index: 1; margin: auto; font-size: 50px; color: transparent; background: linear-gradient(45deg, #a58fe9, #e37682); background-clip: text; -webkit-background-clip: text; } .hexagon:before, .hexagon:after { position: absolute; content: ""; background: inherit; height: 100%; width: 100%; border-radius: 0; transition: 0.5s; transform-origin: center; } .hexagon:before { transform: rotateZ(60deg); } .hexagon:after { transform: rotateZ(-60deg); } .hexagon:hover { border-radius: 50px; transition: 0.5s; } .hexagon:hover:before { border-radius: 50px; transition: 0.5s; } .hexagon:hover:after { border-radius: 50px; transition: 0.5s; } |